const fs = require("fs");
const user = require("../config/user");
function saveAsin(dataCode) {
  return new Promise((resolve, reject) => {
    fs.appendFile("./output/" + user.output + ".txt", dataCode + "\n", "utf8", function (err) {
      if (err) {
        console.log(err);
        reject();
      }
      resolve();
    });

  });
}

// saveAsin()
module.exports = saveAsin;
